<?php 
	class Area_model extends CI_Model{

	 	function __construct(){
        	parent::__construct();
    	}

		function get_list($parent='0'){
            $where = "parent_code = $parent AND status=1";
            $sql = "SELECT * FROM {$this->db->dbprefix}areas WHERE $where  ";
            $result = $this->db->query($sql)->result_array();
            return $result;
        }
    }